<?php
// 多进程数据的共享
use Swoole\Table;

$table = new Table(1024);
$table->column('id', Table::TYPE_INT);
$table->column('name', Table::TYPE_STRING, 255);
$table->create();
$table->set(1, ['id'=>1, 'name'=>'tkkkk']);
$table->set(2, ['id'=>1, 'name'=>'tkkkk']);

var_dump($table->count());

foreach ($table as $key => $row) {
    var_dump(['k'=>$key, 'v'=>$row]);
}